package com.kmproject.haifu.mvp.model.entity;

import java.util.List;

public class ResultBean<T> {
    private int code;
    private String message;
    private T data;
    private String path;
   private  ExtraPageBean  extra;
    private String timestamp;//": "1561096340796"
    /**
     * page : {"current":"1","pages":"1","records":[],"searchCount":true,"size":"1","total":"1"}
     */


    public ResultBean(int code, String message, T data) {
        this.code = code;
        this.message = message;
        this.data = data;
    }

    public ExtraPageBean getExtra() {
        return extra;
    }

    public void setExtra(ExtraPageBean extra) {
        this.extra = extra;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public T getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }



    public static class ExtraPageBean {

        /**
         * page : {"current":"1","limit":10,"order":"","orderBy":"","page":1,"pages":"2","records":[],"requestMap":{"map":""},"searchCount":true,"size":"10","sort":"","total":"11"}
         */

        private PageBean page;

        public PageBean getPage() {
            return page;
        }

        public void setPage(PageBean page) {
            this.page = page;
        }

        public static class PageBean {
            /**
             * current : 1
             * limit : 10
             * order :
             * orderBy :
             * page : 1
             * pages : 2
             * records : []
             * requestMap : {"map":""}
             * searchCount : true
             * size : 10
             * sort :
             * total : 11
             */

            private String current;
            private int limit;
            private String order;
            private String orderBy;
            private int page;
            private String pages;
            private RequestMapBean requestMap;
            private boolean searchCount;
            private String size;
            private String sort;
            private String total;
            private List<?> records;

            public String getCurrent() {
                return current;
            }

            public void setCurrent(String current) {
                this.current = current;
            }

            public int getLimit() {
                return limit;
            }

            public void setLimit(int limit) {
                this.limit = limit;
            }

            public String getOrder() {
                return order;
            }

            public void setOrder(String order) {
                this.order = order;
            }

            public String getOrderBy() {
                return orderBy;
            }

            public void setOrderBy(String orderBy) {
                this.orderBy = orderBy;
            }

            public int getPage() {
                return page;
            }

            public void setPage(int page) {
                this.page = page;
            }

            public String getPages() {
                return pages;
            }

            public void setPages(String pages) {
                this.pages = pages;
            }

            public RequestMapBean getRequestMap() {
                return requestMap;
            }

            public void setRequestMap(RequestMapBean requestMap) {
                this.requestMap = requestMap;
            }

            public boolean isSearchCount() {
                return searchCount;
            }

            public void setSearchCount(boolean searchCount) {
                this.searchCount = searchCount;
            }

            public String getSize() {
                return size;
            }

            public void setSize(String size) {
                this.size = size;
            }

            public String getSort() {
                return sort;
            }

            public void setSort(String sort) {
                this.sort = sort;
            }

            public String getTotal() {
                return total;
            }

            public void setTotal(String total) {
                this.total = total;
            }

            public List<?> getRecords() {
                return records;
            }

            public void setRecords(List<?> records) {
                this.records = records;
            }

            public static class RequestMapBean {
                /**
                 * map :
                 */

                private String map;

                public String getMap() {
                    return map;
                }

                public void setMap(String map) {
                    this.map = map;
                }
            }
        }
    }
}
